// 项目执行代码
const koa = require('koa')
const bodParser = require('koa-bodyparser')
const userRouter = require('../router/user.router')
const app = new koa()
app.use(bodParser())
app.use(userRouter.routes())
//处理预检请求
app.use(userRouter.allowedMethods())

module.exports = app